package com.zkdcloud.constant;

/**
 * 常量
 *
 * @author zk
 * @since 2018/4/10
 */
public interface Constants {
    class HTTP_CONSTANTS {
        /**
         * 请求成功
         */
        public static String HTTP_SUCCESS = "请求成功";
        /**
         * 操作成功
         */
        public static String OPERATOR_SUCCESS = "操作成功";
        /**
         * request属性中的adminUser
         */
        public static String REQUEST_ADMIN = "adminUser";
        /**
         * request属性中的user
         */
        public static String REQUEST_USER = "normalUser";
    }
    public static class HTTP{
        /**
         * http return success tip
         */
        public static final String HTTP_SUCCESS = "请求成功";
        /**
         * http return fail tip
         */
        public static final String HTTP_FAIL = "请求失败";
        /**
         * 操作成功
         */
        public static final String OPERATOR_SUCCESS = "操作成功";
    }

    public static class PROPERTIES{
        /**
         * 初始化文件
         */
        public static final String INIT_PROPERTIES = "start.properties";
        /**
         * db.url
         */
        public static final String DB_URL="db.url";
        /**
         * db.driver
         */
        public static final String DB_DRIVER="db.driver";
        /**
         * db.username
         */
        public static final String DB_USERNAME="db.username";
        /**
         * db.password
         */
        public static final String DB_PASSWORD="db.password";
        /**
         * init db flag
         */
        public static final String DB_INIT = "db.init";
    }

    public static class SYSTEM{
        /**
         * init sql fileName
         */
        public static final String INIT_SQL_FILENAME = "init.sql";
        /**
         * the header of http csrf token
         */
        public static final String CSRF_TOKEN_HEADER = "token";
        /**
         * the flag of session(user login)
         */
        public static final String LOGIN_USER = "login.user";
    }
}
